package com.genius.smsbase.util;

import com.genius.smsbase.Domain.Result;

/**
 * @ClassName ResultUtil
 * @Description ResultUtil
 * @author：
 */
public class ResultUtil {


    public static Result success(String message){
        Result result = new Result();
        result.setCode(200);
        result.setMessage(message);
        return result;
    }
    public static Result success(Integer code,String message){
        Result result = new Result();
        result.setCode(code);
        result.setMessage(message);
        return result;
    }
    public static Result error(String message){
        Result result = new Result();
        result.setCode(500);
        result.setMessage(message);
        return result;
    }
    public static Result error(Integer code,String message){
        Result result = new Result();
        result.setCode(code);
        result.setMessage(message);
        return result;
    }

}
